<?php if (!defined('__ACCESS__')) exit;?> 
		<script type="text/javascript" src="<?php $this->path('js/checkbox.js');?>"></script>
		<script type="text/javascript" src="<?php $this->path('js/validate.js');?>"></script>
		<script type="text/javascript" src="<?php $this->path('js/cookie.js');?>"></script>
		<script type="text/javascript">
    		$(document).ready(function() {
    			$(".registed").validate({
    				rules: {
        				username: {
        					required: true,
        					minlength: 4
        				},
        				password: {
        					required: true,
        					minlength: 4
        				},
        				messages: {
        					username: {
        						required: "<br />Please enter a username",
        						minlength: "<br />Your username must consist of at least 4 characters"
        					},
        					password: {
        						required: "<br />Please provide a password",
        						minlength: "<br />Your password must be at least 5 characters long"
        					},
        				}
        			}
        		});
        		$('.niceCheck').click(function(){
        			if($(this).find('input').is(':checked')){
        				$.cookie("lvtuser", $('.username input').val());
        				$.cookie("lvtpass", $('.password input').val());
        			}else{
        				$.cookie("lvtuser", "");
        				$.cookie("lvtpass", "");
        			}
        		});
        		$('.username input').val($.cookie("lvtuser"));
        		$('.password input').val($.cookie("lvtpass"));
        		if($('.username input').val().length > 0){
        			$('.niceCheck').addClass('niceChecked');
        			$('.niceCheck input').attr('checked',true);
				}
        	});
		</script>
		<section id="main" class="login entire_width">
			<div class="container_12">      
				<div id="content">
					<div class="grid_12">
						<h1 class="page_title">Login or Create an Account</h1>
					</div><!-- .grid_12 -->
		
					<div class="grid_6 new_customers">
						<h2>New Customers</h2>
						<p>By creating an account with our store, you will be able to move through the checkout process faster, store multiple shipping addresses, view and track your orders in your account and more.</p>
						<div class="clear"></div>
						<form action="?module=register" method="post">
						<button class="account" href="?module=register">Create An Account</button>
						</form>
					</div><!-- .grid_6 -->
		
					<div class="grid_6" style="width:500px;">
						<form class="registed" action="?module=login" method="post" autocomplete="off" onsubmit="$('.niceCheck').trigger('click')">
    						<h2>Registered Customers</h2>
    						<p>If you have an account with us, please log in.</p>
    						<?php if( $this->error != ""){ ?>
    						<div class="response-msg error ui-corner-all">
    							<span>Login Failed</span>
    							<?php echo $this->error; ?>
    						</div>					
    						<?php } ?>	
    						<div class="username">
								<strong>Username/Email:</strong><sup class="surely">*</sup><br>
								<input type="text" name="username" class="" value="">
							</div><!-- .usename -->
							
							<div class="password">
    							<strong>Password:</strong><sup class="surely">*</sup><br>
    							<input type="password" name="password" class="" value="">
    							<a class="forgot" href="#">Forgot Your Password?</a>
							</div><!-- .password -->
				
							<div class="remember">
								<span class="niceCheck"><input type="checkbox" name="Remember_password" id="undefined" value="on" tabindex="0"></span>
								<span class="rem">Remember password</span>
							</div><!-- .remember -->
				
							<div class="submit">										
								<input type="submit" value="Login">
								<sup class="surely">*</sup><span>Required Field</span>
							</div><!-- .submit -->
						</form><!-- .registed -->
					</div><!-- .grid_6 -->
				</div><!-- #content -->
				<div class="clear"></div>
				</div><!-- .container_12 -->
			</section>
			<div class="clear"></div>